﻿using System;
using System.Collections.Generic;
using System.IO;
using System.Net;
using System.Text;

namespace A_Modules.Sharepoint
{
    public class ClientConnect
    {
        public void Test()
        {
            String strSourceUrl = @"https://www.iconnect.alere.com/docs/pte/Alere%20Australia/Paid%20Invoices/@3.22/";
//@"https://www.iconnect.alere.com/docs/pte/Alere%20Australia/Paid%20Invoices/@3.22/56712.pdf";
            //56712.pdf
            WebClient _webClient = new WebClient();
            NetworkCredential _credential = new NetworkCredential(@"he.liu",@"HeLi2013",@"ASIAPAC");

            _webClient.Credentials = _credential;
            //_webClient.
            _webClient.BaseAddress = @"https://www.iconnect.alere.com/docs/pte/";
            Byte[] filecontents = _webClient.DownloadData(strSourceUrl); 


        }
    }
}
